LCOV - code coverage report
Current view: top level - vcl/generic/print - prtsetup.cxx (source / functions) Hit Total Coverage
Test: commit 10e77ab3ff6f4314137acd6e2702a6e5c1ce1fae Lines: 1 254 0.4 %
Date: 2014-11-03 Functions: 2 30 6.7 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
       2             : /*
       3             :  * This file is part of the LibreOffice project.
       4             :  *
       5             :  * This Source Code Form is subject to the terms of the Mozilla Public
       6             :  * License, v. 2.0. If a copy of the MPL was not distributed with this
       7             :  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
       8             :  *
       9             :  * This file incorporates work covered by the following license notice:
      10             :  *
      11             :  *   Licensed to the Apache Software Foundation (ASF) under one or more
      12             :  *   contributor license agreements. See the NOTICE file distributed
      13             :  *   with this work for additional information regarding copyright
      14             :  *   ownership. The ASF licenses this file to you under the Apache
      15             :  *   License, Version 2.0 (the "License"); you may not use this file
      16             :  *   except in compliance with the License. You may obtain a copy of
      17             :  *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
      18             :  */
      19             : 
      20             : #include "prtsetup.hxx"
      21             : #include "svdata.hxx"
      22             : #include "svids.hrc"
      23             : 
      24             : #include "osl/thread.h"
      25             : 
      26             : #include <officecfg/Office/Common.hxx>
      27             : 
      28             : using namespace psp;
      29             : 
      30           0 : void RTSDialog::insertAllPPDValues( ListBox& rBox, const PPDParser* pParser, const PPDKey* pKey )
      31             : {
      32           0 :     if( ! pKey || ! pParser )
      33           0 :         return;
      34             : 
      35           0 :     const PPDValue* pValue = NULL;
      36           0 :     sal_Int32 nPos = 0;
      37           0 :     OUString aOptionText;
      38             : 
      39           0 :     for( int i = 0; i < pKey->countValues(); i++ )
      40             :     {
      41           0 :         pValue = pKey->getValue( i );
      42           0 :         if (pValue->m_bCustomOption)
      43           0 :             continue;
      44           0 :         aOptionText = pParser->translateOption( pKey->getKey(), pValue->m_aOption) ;
      45             : 
      46           0 :         if( m_aJobData.m_aContext.checkConstraints( pKey, pValue ) )
      47             :         {
      48           0 :             if( rBox.GetEntryPos( (void*)pValue ) == LISTBOX_ENTRY_NOTFOUND )
      49             :             {
      50           0 :                 nPos = rBox.InsertEntry( aOptionText, LISTBOX_APPEND );
      51           0 :                     rBox.SetEntryData( nPos, (void*)pValue );
      52             :             }
      53             :         }
      54             :         else
      55             :         {
      56           0 :             if( ( nPos = rBox.GetEntryPos( (void*)pValue ) ) != LISTBOX_ENTRY_NOTFOUND )
      57           0 :                 rBox.RemoveEntry( nPos );
      58             :         }
      59             :     }
      60           0 :     pValue = m_aJobData.m_aContext.getValue( pKey );
      61           0 :     if (pValue && !pValue->m_bCustomOption)
      62             :     {
      63           0 :         if( ( nPos = rBox.GetEntryPos( (void*)pValue ) ) != LISTBOX_ENTRY_NOTFOUND )
      64           0 :             rBox.SelectEntryPos( nPos );
      65             :     }
      66             :     else
      67           0 :         rBox.SelectEntry( m_aInvalidString );
      68             : }
      69             : 
      70             : /*
      71             :  * RTSDialog
      72             :  */
      73             : 
      74           0 : RTSDialog::RTSDialog(const PrinterInfo& rJobData, vcl::Window* pParent)
      75             :     : TabDialog(pParent, "PrinterPropertiesDialog", "vcl/ui/printerpropertiesdialog.ui")
      76             :     , m_aJobData(rJobData)
      77             :     , m_pPaperPage(NULL)
      78             :     , m_pDevicePage(NULL)
      79           0 :     , m_aInvalidString(VclResId(SV_PRINT_INVALID_TXT))
      80             : {
      81           0 :     get(m_pOKButton, "ok");
      82           0 :     get(m_pCancelButton, "cancel");
      83           0 :     get(m_pTabControl, "notebook");
      84             : 
      85           0 :     OUString aTitle(GetText());
      86           0 :     SetText(aTitle.replaceAll("%s", m_aJobData.m_aPrinterName));
      87             : 
      88           0 :     m_pTabControl->SetActivatePageHdl( LINK( this, RTSDialog, ActivatePage ) );
      89           0 :     m_pOKButton->SetClickHdl( LINK( this, RTSDialog, ClickButton ) );
      90           0 :     m_pCancelButton->SetClickHdl( LINK( this, RTSDialog, ClickButton ) );
      91           0 :     ActivatePage(m_pTabControl);
      92           0 : }
      93             : 
      94           0 : RTSDialog::~RTSDialog()
      95             : {
      96           0 :     delete m_pPaperPage;
      97           0 :     delete m_pDevicePage;
      98           0 : }
      99             : 
     100           0 : IMPL_LINK( RTSDialog, ActivatePage, TabControl*, pTabCtrl )
     101             : {
     102           0 :     if( pTabCtrl != m_pTabControl )
     103           0 :         return 0;
     104             : 
     105           0 :     sal_uInt16 nId = m_pTabControl->GetCurPageId();
     106           0 :     OString sPage = m_pTabControl->GetPageName(nId);
     107           0 :     if ( ! m_pTabControl->GetTabPage( nId ) )
     108             :     {
     109           0 :         TabPage *pPage = NULL;
     110           0 :         if (sPage == "paper")
     111           0 :             pPage = m_pPaperPage = new RTSPaperPage( this );
     112           0 :         else if (sPage == "device")
     113           0 :             pPage = m_pDevicePage = new RTSDevicePage( this );
     114           0 :         if( pPage )
     115           0 :             m_pTabControl->SetTabPage( nId, pPage );
     116             :     }
     117             :     else
     118             :     {
     119           0 :         if (sPage == "paper")
     120           0 :             m_pPaperPage->update();
     121           0 :         else if (sPage == "device")
     122           0 :             m_pDevicePage->update();
     123             :     }
     124             : 
     125           0 :     return 0;
     126             : }
     127             : 
     128           0 : IMPL_LINK( RTSDialog, ClickButton, Button*, pButton )
     129             : {
     130           0 :     if( pButton == m_pOKButton )
     131             :     {
     132             :         // refresh the changed values
     133           0 :         if( m_pPaperPage )
     134             :         {
     135             :             // orientation
     136           0 :             m_aJobData.m_eOrientation = m_pPaperPage->getOrientation() == 0 ?
     137           0 :                 orientation::Portrait : orientation::Landscape;
     138             :         }
     139           0 :         if( m_pDevicePage )
     140             :         {
     141           0 :             m_aJobData.m_nColorDepth    = m_pDevicePage->getDepth();
     142           0 :             m_aJobData.m_nColorDevice   = m_pDevicePage->getColorDevice();
     143           0 :             m_aJobData.m_nPSLevel       = m_pDevicePage->getLevel();
     144           0 :             m_aJobData.m_nPDFDevice     = m_pDevicePage->getPDFDevice();
     145             :         }
     146           0 :         EndDialog( 1 );
     147             :     }
     148           0 :     else if( pButton == m_pCancelButton )
     149           0 :         EndDialog( 0 );
     150             : 
     151           0 :     return 0;
     152             : }
     153             : 
     154             : /*
     155             :  * RTSPaperPage
     156             :  */
     157             : 
     158           0 : RTSPaperPage::RTSPaperPage(RTSDialog* pParent)
     159             :     : TabPage(pParent->m_pTabControl, "PrinterPaperPage", "vcl/ui/printerpaperpage.ui")
     160           0 :     , m_pParent( pParent )
     161             : {
     162           0 :     get(m_pPaperText, "paperft");
     163           0 :     get(m_pPaperBox, "paperlb");
     164           0 :     get(m_pOrientBox, "orientlb");
     165           0 :     get(m_pDuplexText, "duplexft");
     166           0 :     get(m_pDuplexBox, "duplexlb");
     167           0 :     get(m_pSlotText, "slotft");
     168           0 :     get(m_pSlotBox, "slotlb");
     169             : 
     170           0 :     m_pPaperBox->SetSelectHdl( LINK( this, RTSPaperPage, SelectHdl ) );
     171           0 :     m_pOrientBox->SetSelectHdl( LINK( this, RTSPaperPage, SelectHdl ) );
     172           0 :     m_pDuplexBox->SetSelectHdl( LINK( this, RTSPaperPage, SelectHdl ) );
     173           0 :     m_pSlotBox->SetSelectHdl( LINK( this, RTSPaperPage, SelectHdl ) );
     174             : 
     175           0 :     sal_Int32 nPos = 0;
     176             : 
     177             :     // duplex
     178           0 :     nPos = m_pDuplexBox->InsertEntry( m_pParent->m_aInvalidString );
     179           0 :     m_pDuplexBox->SetEntryData( nPos, NULL );
     180             : 
     181             :     // paper does not have an invalid entry
     182             : 
     183             :     // input slots
     184           0 :     nPos = m_pSlotBox->InsertEntry( m_pParent->m_aInvalidString );
     185           0 :     m_pSlotBox->SetEntryData( nPos, NULL );
     186             : 
     187           0 :     update();
     188           0 : }
     189             : 
     190           0 : RTSPaperPage::~RTSPaperPage()
     191             : {
     192           0 : }
     193             : 
     194           0 : void RTSPaperPage::update()
     195             : {
     196           0 :     const PPDKey* pKey      = NULL;
     197             : 
     198             :     // orientation
     199             :     m_pOrientBox->SelectEntryPos(
     200           0 :         m_pParent->m_aJobData.m_eOrientation == orientation::Portrait ? 0 : 1);
     201             : 
     202             :     // duplex
     203           0 :     if( m_pParent->m_aJobData.m_pParser &&
     204           0 :         (pKey = m_pParent->m_aJobData.m_pParser->getKey( OUString( "Duplex" ) )) )
     205             :     {
     206           0 :         m_pParent->insertAllPPDValues( *m_pDuplexBox, m_pParent->m_aJobData.m_pParser, pKey );
     207             :     }
     208             :     else
     209             :     {
     210           0 :         m_pDuplexText->Enable( false );
     211           0 :         m_pDuplexBox->Enable( false );
     212             :     }
     213             : 
     214             :     // paper
     215           0 :     if( m_pParent->m_aJobData.m_pParser &&
     216           0 :         (pKey = m_pParent->m_aJobData.m_pParser->getKey( OUString( "PageSize" ) )) )
     217             :     {
     218           0 :         m_pParent->insertAllPPDValues( *m_pPaperBox, m_pParent->m_aJobData.m_pParser, pKey );
     219             :     }
     220             :     else
     221             :     {
     222           0 :         m_pPaperText->Enable( false );
     223           0 :         m_pPaperBox->Enable( false );
     224             :     }
     225             : 
     226             :     // input slots
     227           0 :     if( m_pParent->m_aJobData.m_pParser &&
     228           0 :         (pKey = m_pParent->m_aJobData.m_pParser->getKey( OUString("InputSlot") )) )
     229             :     {
     230           0 :         m_pParent->insertAllPPDValues( *m_pSlotBox, m_pParent->m_aJobData.m_pParser, pKey );
     231             :     }
     232             :     else
     233             :     {
     234           0 :         m_pSlotText->Enable( false );
     235           0 :         m_pSlotBox->Enable( false );
     236             :     }
     237           0 : }
     238             : 
     239           0 : IMPL_LINK( RTSPaperPage, SelectHdl, ListBox*, pBox )
     240             : {
     241           0 :     const PPDKey* pKey = NULL;
     242           0 :     if( pBox == m_pPaperBox )
     243             :     {
     244           0 :         if( m_pParent->m_aJobData.m_pParser )
     245           0 :             pKey = m_pParent->m_aJobData.m_pParser->getKey( OUString( "PageSize" ) );
     246             :     }
     247           0 :     else if( pBox == m_pDuplexBox )
     248             :     {
     249           0 :         if( m_pParent->m_aJobData.m_pParser )
     250           0 :             pKey = m_pParent->m_aJobData.m_pParser->getKey( OUString( "Duplex" ) );
     251             :     }
     252           0 :     else if( pBox == m_pSlotBox )
     253             :     {
     254           0 :         if( m_pParent->m_aJobData.m_pParser )
     255           0 :             pKey = m_pParent->m_aJobData.m_pParser->getKey( OUString( "InputSlot" ) );
     256             :     }
     257           0 :     else if( pBox == m_pOrientBox )
     258             :     {
     259           0 :         m_pParent->m_aJobData.m_eOrientation = m_pOrientBox->GetSelectEntryPos() == 0 ? orientation::Portrait : orientation::Landscape;
     260             :     }
     261           0 :     if( pKey )
     262             :     {
     263             :         PPDValue* pValue =
     264           0 :             (PPDValue*)pBox->GetEntryData( pBox->GetSelectEntryPos() );
     265           0 :         m_pParent->m_aJobData.m_aContext.setValue( pKey, pValue );
     266           0 :         update();
     267             :     }
     268           0 :     return 0;
     269             : }
     270             : 
     271             : /*
     272             :  * RTSDevicePage
     273             :  */
     274             : 
     275           0 : RTSDevicePage::RTSDevicePage( RTSDialog* pParent )
     276             :     : TabPage(pParent->m_pTabControl, "PrinterDevicePage", "vcl/ui/printerdevicepage.ui")
     277             :     , m_pParent(pParent)
     278           0 :     , m_pCustomValue(NULL)
     279             : {
     280           0 :     get(m_pPPDKeyBox, "options");
     281           0 :     get(m_pPPDValueBox, "values");
     282             : 
     283           0 :     m_pPPDKeyBox->SetDropDownLineCount(12);
     284           0 :     m_pPPDValueBox->SetDropDownLineCount(12);
     285             : 
     286           0 :     get(m_pCustomEdit, "custom");
     287           0 :     m_pCustomEdit->SetModifyHdl(LINK(this, RTSDevicePage, ModifyHdl));
     288             : 
     289           0 :     get(m_pLevelBox, "level");
     290           0 :     get(m_pSpaceBox, "colorspace");
     291           0 :     get(m_pDepthBox, "colordepth");
     292             : 
     293           0 :     m_pPPDKeyBox->SetSelectHdl( LINK( this, RTSDevicePage, SelectHdl ) );
     294           0 :     m_pPPDValueBox->SetSelectHdl( LINK( this, RTSDevicePage, SelectHdl ) );
     295             : 
     296           0 :     switch( m_pParent->m_aJobData.m_nColorDevice )
     297             :     {
     298           0 :         case  0: m_pSpaceBox->SelectEntryPos(0);break;
     299           0 :         case  1: m_pSpaceBox->SelectEntryPos(1);break;
     300           0 :         case -1: m_pSpaceBox->SelectEntryPos(2);break;
     301             :     }
     302             : 
     303           0 :     sal_uLong nLevelEntryData = 0; //automatic
     304           0 :     if( m_pParent->m_aJobData.m_nPDFDevice == 2 ) //explicitly PDF
     305           0 :         nLevelEntryData = 10;
     306           0 :     else if (m_pParent->m_aJobData.m_nPSLevel > 0) //explicit PS Level
     307           0 :         nLevelEntryData = m_pParent->m_aJobData.m_nPSLevel+1;
     308           0 :     else if (m_pParent->m_aJobData.m_nPDFDevice == 1) //automatically PDF
     309           0 :         nLevelEntryData = 0;
     310           0 :     else if (m_pParent->m_aJobData.m_nPDFDevice == -1) //explicitly PS from driver
     311           0 :         nLevelEntryData = 1;
     312             : 
     313           0 :     bool bAutoIsPDF = officecfg::Office::Common::Print::Option::Printer::PDFAsStandardPrintJobFormat::get();
     314             : 
     315             :     assert(nLevelEntryData != 0
     316             :             || "Generic Printer" == m_pParent->m_aJobData.m_aPrinterName
     317             :             || int(bAutoIsPDF) == m_pParent->m_aJobData.m_nPDFDevice);
     318             : 
     319           0 :     OUString sStr = m_pLevelBox->GetEntry(0);
     320           0 :     m_pLevelBox->InsertEntry(sStr.replaceAll("%s", bAutoIsPDF ? m_pLevelBox->GetEntry(5) : m_pLevelBox->GetEntry(1)), 0);
     321           0 :     m_pLevelBox->SetEntryData(0, m_pLevelBox->GetEntryData(1));
     322           0 :     m_pLevelBox->RemoveEntry(1);
     323             : 
     324           0 :     for( sal_uInt16 i = 0; i < m_pLevelBox->GetEntryCount(); i++ )
     325             :     {
     326           0 :         if( reinterpret_cast<sal_uLong>(m_pLevelBox->GetEntryData( i )) == nLevelEntryData )
     327             :         {
     328           0 :             m_pLevelBox->SelectEntryPos( i );
     329           0 :             break;
     330             :         }
     331             :     }
     332             : 
     333           0 :     if (m_pParent->m_aJobData.m_nColorDepth == 8)
     334           0 :         m_pDepthBox->SelectEntryPos(0);
     335           0 :     else if (m_pParent->m_aJobData.m_nColorDepth == 24)
     336           0 :         m_pDepthBox->SelectEntryPos(1);
     337             : 
     338             :     // fill ppd boxes
     339           0 :     if( m_pParent->m_aJobData.m_pParser )
     340             :     {
     341           0 :         for( int i = 0; i < m_pParent->m_aJobData.m_pParser->getKeys(); i++ )
     342             :         {
     343           0 :             const PPDKey* pKey = m_pParent->m_aJobData.m_pParser->getKey( i );
     344           0 :             if( pKey->isUIKey()                                 &&
     345           0 :                 ! pKey->getKey().equalsAscii( "PageSize" )      &&
     346           0 :                 ! pKey->getKey().equalsAscii( "InputSlot" )     &&
     347           0 :                 ! pKey->getKey().equalsAscii( "PageRegion" )    &&
     348           0 :                 ! pKey->getKey().equalsAscii( "Duplex" )
     349             :                 )
     350             :             {
     351           0 :                 OUString aEntry( m_pParent->m_aJobData.m_pParser->translateKey( pKey->getKey() ) );
     352           0 :                 sal_uInt16 nPos = m_pPPDKeyBox->InsertEntry( aEntry );
     353           0 :                 m_pPPDKeyBox->SetEntryData( nPos, (void*)pKey );
     354             :             }
     355             :         }
     356           0 :     }
     357           0 : }
     358             : 
     359           0 : RTSDevicePage::~RTSDevicePage()
     360             : {
     361           0 : }
     362             : 
     363           0 : void RTSDevicePage::update()
     364             : {
     365           0 : }
     366             : 
     367           0 : sal_uLong RTSDevicePage::getDepth()
     368             : {
     369           0 :     sal_uInt16 nSelectPos = m_pDepthBox->GetSelectEntryPos();
     370           0 :     if (nSelectPos == 0)
     371           0 :         return 8;
     372             :     else
     373           0 :         return 24;
     374             : }
     375             : 
     376           0 : sal_uLong RTSDevicePage::getColorDevice()
     377             : {
     378           0 :     sal_uInt16 nSelectPos = m_pSpaceBox->GetSelectEntryPos();
     379           0 :     switch (nSelectPos)
     380             :     {
     381             :         case 0:
     382           0 :             return 0;
     383             :         case 1:
     384           0 :             return 1;
     385             :         case 2:
     386           0 :             return -1;
     387             :     }
     388           0 :     return 0;
     389             : }
     390             : 
     391           0 : sal_uLong RTSDevicePage::getLevel()
     392             : {
     393           0 :     sal_uLong nLevel = reinterpret_cast<sal_uLong>(m_pLevelBox->GetEntryData( m_pLevelBox->GetSelectEntryPos() ));
     394           0 :     if (nLevel == 0)
     395           0 :         return 0;   //automatic
     396           0 :     return nLevel < 10 ? nLevel-1 : 0;
     397             : }
     398             : 
     399           0 : sal_uLong RTSDevicePage::getPDFDevice()
     400             : {
     401           0 :     sal_uLong nLevel = reinterpret_cast<sal_uLong>(m_pLevelBox->GetEntryData( m_pLevelBox->GetSelectEntryPos() ));
     402           0 :     if (nLevel > 9)
     403           0 :         return 2;   //explictly PDF
     404           0 :     else if (nLevel == 0)
     405           0 :         return 0;   //automatic
     406           0 :     return -1;      //explicitly PS
     407             : }
     408             : 
     409           0 : IMPL_LINK(RTSDevicePage, ModifyHdl, Edit*,  pEdit)
     410             : {
     411           0 :     if (m_pCustomValue)
     412             :     {
     413           0 :         m_pCustomValue->m_aCustomOption = pEdit->GetText();
     414             :     }
     415           0 :     return 0;
     416             : }
     417             : 
     418           0 : IMPL_LINK( RTSDevicePage, SelectHdl, ListBox*, pBox )
     419             : {
     420           0 :     if( pBox == m_pPPDKeyBox )
     421             :     {
     422           0 :         const PPDKey* pKey = (PPDKey*)m_pPPDKeyBox->GetEntryData( m_pPPDKeyBox->GetSelectEntryPos() );
     423           0 :         FillValueBox( pKey );
     424             :     }
     425           0 :     else if( pBox == m_pPPDValueBox )
     426             :     {
     427           0 :         const PPDKey* pKey = (PPDKey*)m_pPPDKeyBox->GetEntryData( m_pPPDKeyBox->GetSelectEntryPos() );
     428           0 :         const PPDValue* pValue = (PPDValue*)m_pPPDValueBox->GetEntryData( m_pPPDValueBox->GetSelectEntryPos() );
     429           0 :         if (pKey && pValue)
     430             :         {
     431           0 :             m_pParent->m_aJobData.m_aContext.setValue( pKey, pValue );
     432           0 :             FillValueBox( pKey );
     433             :         }
     434             :     }
     435           0 :     return 0;
     436             : }
     437             : 
     438           0 : void RTSDevicePage::FillValueBox( const PPDKey* pKey )
     439             : {
     440           0 :     m_pPPDValueBox->Clear();
     441           0 :     m_pCustomEdit->Hide();
     442             : 
     443           0 :     if( ! pKey )
     444           0 :         return;
     445             : 
     446           0 :     const PPDValue* pValue = NULL;
     447           0 :     for( int i = 0; i < pKey->countValues(); i++ )
     448             :     {
     449           0 :         pValue = pKey->getValue( i );
     450           0 :         if( m_pParent->m_aJobData.m_aContext.checkConstraints( pKey, pValue ) &&
     451             :             m_pParent->m_aJobData.m_pParser )
     452             :         {
     453           0 :             OUString aEntry;
     454           0 :             if (pValue->m_bCustomOption)
     455           0 :                 aEntry = VclResId(SV_PRINT_CUSTOM_TXT);
     456             :             else
     457           0 :                 aEntry = OUString(m_pParent->m_aJobData.m_pParser->translateOption( pKey->getKey(), pValue->m_aOption));
     458           0 :             sal_uInt16 nPos = m_pPPDValueBox->InsertEntry( aEntry );
     459           0 :             m_pPPDValueBox->SetEntryData( nPos, (void*)pValue );
     460             :         }
     461             :     }
     462           0 :     pValue = m_pParent->m_aJobData.m_aContext.getValue( pKey );
     463           0 :     m_pPPDValueBox->SelectEntryPos( m_pPPDValueBox->GetEntryPos( (void*)pValue ) );
     464           0 :     if (pValue->m_bCustomOption)
     465             :     {
     466           0 :         m_pCustomValue = pValue;
     467           0 :         m_pParent->m_aJobData.m_aContext.setValue(pKey, pValue);
     468           0 :         m_pCustomEdit->SetText(m_pCustomValue->m_aCustomOption);
     469           0 :         m_pCustomEdit->Show();
     470             :     }
     471             : }
     472             : 
     473           0 : int SetupPrinterDriver(::psp::PrinterInfo& rJobData)
     474             : {
     475           0 :     int nRet = 0;
     476           0 :     RTSDialog aDialog( rJobData, NULL );
     477             : 
     478           0 :     if( aDialog.Execute() )
     479             :     {
     480           0 :         rJobData = aDialog.getSetup();
     481           0 :         nRet = 1;
     482             :     }
     483             : 
     484           0 :     return nRet;
     485        1233 : }
     486             : 
     487             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10