quick_recipes (779892), страница 58

Файл №779892 quick_recipes (Symbian Books) 58 страницаquick_recipes (779892) страница 582018-01-10СтудИзба
Просмтор этого файла доступен только зарегистрированным пользователям. Но у нас супер быстрая регистрация: достаточно только электронной почты!

Текст из файла (страница 58)

You can refine this with CQikDurationEditor or CQikTimeEditor.CQikBuildingBlock will help you with the layout of the screen.CQikColorSelector will be most useful when the user has to drawsomething or to allow visual customization.File manipulation is usually helped by CQikSelectFileDlg, CQikSelectForlderDlg, CQikCopyFilesAndFoldersDlg, CQikMoveFilesAndFoldersDlg and CQikRenameFileorfolderDlg.Some advanced drawing primitives are defined in the QikDrawUtilsclass.Some even more advanced and animated GUI components can evenbe used, like RQikdigitalClock.We recommend that you read the ‘Programmer’s guide to new featuresin UIQ 3’ that you will find in the UIQ documentation, and that you takea look at UIQ 3: The Complete Guide at books.uiq.com.5.1.4 Advanced Messaging: A New ProtocolSymbian OS defines the concept of Message Type Module (MTM). AnMTM plug-in is a set of binaries that extend the messaging featuresof a handset, with the help of the Messaging Store and the MessagingServer.

An MTM can be used for several purposes: bypassing the handsetmessaging application (and writing your own), synching your corporatemessages with your handset, creating your own messaging protocol (i.e.,to send messages to a social networking system), and so on.An MTM is composed of a minimum of four libraries:• a client DLL• a client UI DLL• a client UI data DLL• a server DLL.Each DLL has a specific UID that indicates which part of an MTM it is.In addition, you will need to allocate another UID for each DLL and anextra UID for the new MTM as a whole.The server DLL, as its name indicates, is only loaded by the messagingserver.The three client-side DLLs should be available to all messaging-relatedapplications, not just any applications you would write.The MTM server DLL that you will develop needs to be able to listenfor incoming messages via the networking or telephony APIs.

A new324NEXT LEVEL DEVELOPMENTmessage event can also simply be triggered by a message being movedto the Inbox folder.The MTM client DLL needs to translate basic messaging operationsinto the correct binary format for the messaging protocol. For example, arecipient address would have a different format for email than for SMS.The MTM client UI DLL mirrors the MTM server DLL a lot. Thisis where the messaging application forwards user requests like movingmessages between folders.The MTM client UI data DLL is the interface with the messagingbrowser on your handset. This means checking how messages can betransferred from one MTM to another and customizing the look of themessaging browser with your own icons.What you cannot change right now, on any platform, is the waythe message index browser (the application that shows you the differentmessaging services and folders) handles folders and messaging accountentries.

The messaging browser will display the icons you want it to andit will launch your messaging application, but you may not be able toforce it to display your MTM’s Inbox as a special item, for example.The message browser could be the same actual binary as the defaultmessaging application on your handset. However, this won’t prevent youfrom developing your own messaging application. The handset just needssomething to act as a messaging browser, capable of handling messagingdatabase entries regardless of the MTM to which they ‘belong’.Similarly, the default messaging application on your handset could beable to handle SMS, MMS and email messages even though these serviceswould typically be implemented as three different MTMs since the binaryformats and networking protocols are so wildly different.When writing a new messaging application, you should make fulluse of the GUI controls, views and dialogs already available in yourplatform, including the ones discussed in Section 5.1.3 as they allow youto simplify the logic behind adding recipients to a message or schedulingmeetings.Developing a new messaging application is anticipated to get easierfrom Symbian OS v9.3 on S60 as the main messaging application becomesmore customizable.You should also expect any messaging application you develop toneed engine-level (as opposed to GUI) changes when running on differentplatforms.

The basic structure of folders and accounts under a serviceentry is different in S60 and UIQ. You will need to experiment for a littlewhile.Finally, simply installing DLLs from a SIS file is not enough for a newMTM to become available to the entire operating system. You also needto use the CMtmRegistryControl API. See Section 5.3.2 for how todo this at install-time.SYMBIAN PARTNERS ONLY325It is technically possible to develop an MTM without becoming aSymbian partner and procuring a DevKit, but we don’t recommend it. Infact, some experts regard MTMs as the single most difficult Symbian OSC++ development endeavor, but the select few who have seen it throughto completion don’t regret it.

(That last part was an outright lie.)If you plan on attempting to develop a new MTM with extendedfunctionality, we recommend that you read chapters 8 and 9 of IainCampbell’s Symbian OS Communications Programming, 2nd Editionfrom Symbian Press (developer.symbian.com/commsbook).5.2 Symbian Partners OnlySeveral advanced features cannot be properly implemented withoutbecoming a Symbian Partner, which will cost you money but gives accessto more development resources (plus some additional benefits, which aredescribed in Chapter 6, Section 6.3.2). The technical paper What Symbian development kit do I need is also a useful place to find more information, and is available at www.symbian.com/symbianos/whitepapers/whitepaperscasestudies.html.5.2.1 File Server Plug-in: Separate File SystemBy now, you already know that file access operations are centralizedin the system’s File Server process. Symbian OS allows you to createplug-ins for this file server to overwrite default behaviors.

This feature iscommonly used to protect parts of the file system through encryption, incase the handset is lost or stolen, but could also be useful for RAID dataduplication or networked storage, and so on.As you can easily imagine, you will require a high level of platformsecurity capability to distribute something that is potentially dangerous.Chapter 6 can help you with that.The first class to look at if you want to develop a file server plug-in isCBaseExtProxyDrive.5.2.2 Advanced Multimedia: Additional Format StreamingAs you have seen from the recipes in Section 4.7, your handset has afairly wide range of multimedia functionality. You can probably play andrecord both audio and video.

Just as importantly, the media data you wantto access doesn’t need to be on your phone, since the media frameworkis able to use a simple URL as input and play what it points to prettymuch just as if it were on your phone – as long as you have the right toaccess it.326NEXT LEVEL DEVELOPMENTSymbian OS contains a modular Multimedia Framework system thatallows you to develop controller plug-ins that can extend those multimedia capabilities. Controller plug-ins can be used to support more mediafile formats and/or more networking protocols, although the emphasis inthe system is that one controller plug-in should, if at all possible, supportall the networking protocols that allow access to a particular set of mediatypes.By default, remote access to media data should be streamed (asopposed to downloaded) by a controller plug-in.The first classes to look at if you want to develop a Multimedia Framework controller plug-in are CMMFController, CMMFAudioOutput, CMMFUrlSource, CMMFFormatDecode, MDataSink andMDataSource.The most well-known and advanced set of source code for a Multimedia Framework controller plug-in can be found at www.helixcommunity.org.5.3 Advanced Application Deployment5.3.1 Automatic InstallationThis is an interesting trick that can greatly benefit a commercial-gradeapplication.Normally, when you select a SIS file and choose to install the application it deploys, the installation process leaves a small stub file in theprivate data-caged folder of the application, saving it on the memorycard.

You can exploit this knowledge to enable automatic installation.If you save the SIS file for your application in its private data-cagedfolder on a clean memory card, application installation will be automatically initiated when the card is put into a device which has not had theapplication previously installed. The installation is not silent, but it doesnot require the user to navigate to the SIS file and start it manually. Theoriginal SIS file is left on the memory card, no stub SIS file is created,which is a potential waste of disk space, depending on the size of the file.This approach only works if the application was never previouslyinstalled on the handset. From a commercial standpoint, it allows youto distribute your application on a memory card, facilitating an extradistribution channel.5.3.2 Custom InstallAs we’ve seen from the examples that accompany this book, applicationsare deployed to the device through SIS files, which are generated bypackaging application binaries according to the instructions in a humanreadable PKG file.

The PKG file can be modified to include binaries thatADVANCED APPLICATION DEPLOYMENT327will be executed at install-time. In the case of a set of binaries that requiresome additional setup, you can structure your PKG file in the followingorder:• A cleanup executable, run at uninstall-time only and blocking (options",FR,RR,RW").• Your binaries.• A setup executable, run at install only and non-blocking (options",FR,RI").The options would be added at the end of the line for the binary in thePKG file.There are many useful features to the PKG file format, like conditionalselection of binaries, language selection (so you can deploy the same SISto several countries without wasting memory on the handsets), displayinginformation dialogs to the user at install-time, and so on.The Symbian Developer Library supplies documentation and examplesof how to use PKG files.

Take a look at the Software Installation Toolkitin the Symbian OS Tools and Utilities section for more information.5.3.3 Embedded BinariesYou can package a SIS file within another SIS file, just like any otherbinary. What this does is effectively embed the SIS file within the enclosingSIS file. At installation time, when the instruction to install the embeddedSIS file is reached, the installation of other files within the enclosing SISfile is automatically interrupted in order to install the embedded SIS.At first sight, this doesn’t really seem like a particularly importantfeature. One could ask, why not copy-and-paste the content of thesmaller PKG file into the bigger one? Use cases become more obviouswhen considering inter-company development, allowing one company toredistribute another company’s binaries.

Характеристики

Тип файла
PDF-файл
Размер
1,59 Mb
Материал
Тип материала
Высшее учебное заведение

Список файлов книги

Свежие статьи
Популярно сейчас
Как Вы думаете, сколько людей до Вас делали точно такое же задание? 99% студентов выполняют точно такие же задания, как и их предшественники год назад. Найдите нужный учебный материал на СтудИзбе!
Ответы на популярные вопросы
Да! Наши авторы собирают и выкладывают те работы, которые сдаются в Вашем учебном заведении ежегодно и уже проверены преподавателями.
Да! У нас любой человек может выложить любую учебную работу и зарабатывать на её продажах! Но каждый учебный материал публикуется только после тщательной проверки администрацией.
Вернём деньги! А если быть более точными, то автору даётся немного времени на исправление, а если не исправит или выйдет время, то вернём деньги в полном объёме!
Да! На равне с готовыми студенческими работами у нас продаются услуги. Цены на услуги видны сразу, то есть Вам нужно только указать параметры и сразу можно оплачивать.
Отзывы студентов
Ставлю 10/10
Все нравится, очень удобный сайт, помогает в учебе. Кроме этого, можно заработать самому, выставляя готовые учебные материалы на продажу здесь. Рейтинги и отзывы на преподавателей очень помогают сориентироваться в начале нового семестра. Спасибо за такую функцию. Ставлю максимальную оценку.
Лучшая платформа для успешной сдачи сессии
Познакомился со СтудИзбой благодаря своему другу, очень нравится интерфейс, количество доступных файлов, цена, в общем, все прекрасно. Даже сам продаю какие-то свои работы.
Студизба ван лав ❤
Очень офигенный сайт для студентов. Много полезных учебных материалов. Пользуюсь студизбой с октября 2021 года. Серьёзных нареканий нет. Хотелось бы, что бы ввели подписочную модель и сделали материалы дешевле 300 рублей в рамках подписки бесплатными.
Отличный сайт
Лично меня всё устраивает - и покупка, и продажа; и цены, и возможность предпросмотра куска файла, и обилие бесплатных файлов (в подборках по авторам, читай, ВУЗам и факультетам). Есть определённые баги, но всё решаемо, да и администраторы реагируют в течение суток.
Маленький отзыв о большом помощнике!
Студизба спасает в те моменты, когда сроки горят, а работ накопилось достаточно. Довольно удобный сайт с простой навигацией и огромным количеством материалов.
Студ. Изба как крупнейший сборник работ для студентов
Тут дофига бывает всего полезного. Печально, что бывают предметы по которым даже одного бесплатного решения нет, но это скорее вопрос к студентам. В остальном всё здорово.
Спасательный островок
Если уже не успеваешь разобраться или застрял на каком-то задание поможет тебе быстро и недорого решить твою проблему.
Всё и так отлично
Всё очень удобно. Особенно круто, что есть система бонусов и можно выводить остатки денег. Очень много качественных бесплатных файлов.
Отзыв о системе "Студизба"
Отличная платформа для распространения работ, востребованных студентами. Хорошо налаженная и качественная работа сайта, огромная база заданий и аудитория.
Отличный помощник
Отличный сайт с кучей полезных файлов, позволяющий найти много методичек / учебников / отзывов о вузах и преподователях.
Отлично помогает студентам в любой момент для решения трудных и незамедлительных задач
Хотелось бы больше конкретной информации о преподавателях. А так в принципе хороший сайт, всегда им пользуюсь и ни разу не было желания прекратить. Хороший сайт для помощи студентам, удобный и приятный интерфейс. Из недостатков можно выделить только отсутствия небольшого количества файлов.
Спасибо за шикарный сайт
Великолепный сайт на котором студент за не большие деньги может найти помощь с дз, проектами курсовыми, лабораторными, а также узнать отзывы на преподавателей и бесплатно скачать пособия.
Популярные преподаватели
Добавляйте материалы
и зарабатывайте!
Продажи идут автоматически
6513
Авторов
на СтудИзбе
302
Средний доход
с одного платного файла
Обучение Подробнее